<%@ page language="java" contentType="text/html; charset=UTF-8"
	pageEncoding="UTF-8"%>
<%@ include file="/WEB-INF/page/public/taglib.jsp"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>资质管理</title>
<%
	request.setAttribute("menu", 1);
%>
<%@ include file="/WEB-INF/page/public/contentmeta.jsp"%>
<link rel="stylesheet" href="<%=basePath%>css/global.css" media="all" />
<link rel="stylesheet" href="<%=basePath%>plugins/font-awesome/css/font-awesome.min.css" media="all">
<link rel="stylesheet" href="<%=basePath%>css/system.css" media="all">
<link rel="stylesheet" href="<%=basePath%>css/tab.css" media="all" />
<style type="text/css">
.layui-form-label i {
	color: red;
	padding-right: 3px;
}
.htlayui-disabled, .htlayui-disabled:hover {
    color: black;
    background-color:#e4e4e4;
    cursor: not-allowed;
}
.layui-form-label {
    float: left;
    display: block;
    padding: 9px 15px;
    width: 130px;
    font-weight: 400;
    text-align: right;
}
</style>

</head>
<body>
	<div  style="margin:15px;">
	
		 <form class="layui-form clefix  " action="/customer/savequalificationitem" method="post" id="customerlistform">
		     <input type="hidden" value="${param.cusid}"       id="cusid" name="cusid">
			<input type="hidden" value="${param.contractid}"       id="contractid" name="contractid">
			<input type="hidden" value="${param.owner}"       id="owner" name="owner">
	<fieldset class="layui-elem-field">
		  <legend>资质要求</legend>
			<c:forEach var="obj" items="${yq}" varStatus="o1">
					<div class="layui-form-item">
						<div class="layui-field-box"> 
						      <label class="layui-form-label">${obj.name}：</label>
						      <c:set  property="itemobj"   var="itemobj" value=""></c:set>
						      <c:set  property="currentstate"   var="currentstate" value="0"></c:set>
						      <c:forEach var="objitem" items="${pager.resultList}" varStatus="o2">
						             <c:if test="${objitem.itemid==obj.value*1}">
						              		 <c:set  property="currentstate"   var="currentstate" value="1"></c:set>
						              		  <c:set  property="itemobj"   var="itemobj" value="${objitem}"></c:set>
						             </c:if> 
						      </c:forEach>
						      <div class="layui-input-inline"   data="${obj.value}"   style="width:60%" >
						      			<input type="hidden" value="${obj.value}"       name="itemid">
					        	 	    <input type="text" name="content"         value="<c:if test="${currentstate==1}">${itemobj.content}</c:if>"   placeholder="请输入${obj.name}" autocomplete="off" class="layui-input">
					          </div>
					            <c:if test="${currentstate==1}">
					            		 <div class="layui-form-mid layui-word-aux">${itemobj.createuserName}于${itemobj.createdate.substring(0,16)}  更新</div>
					            </c:if> 
						 </div>
					</div>	 
			</c:forEach> 
		  
		</fieldset>
  
	
		<fieldset class="layui-elem-field">
		  <legend>资质情况</legend>
			<c:forEach var="obj" items="${item}" varStatus="o1">
					<div class="layui-form-item">
						<div class="layui-field-box"> 
						      <label class="layui-form-label">${obj.name}：</label> 
						      <c:set  property="itemobj"   var="itemobj" value=""></c:set>
						      <c:set  property="currentstate"   var="currentstate" value="0"></c:set>
						      <c:forEach var="objitem" items="${pager.resultList}" varStatus="o2">
						             <c:if test="${objitem.itemid==obj.value*1}">
						              		 <c:set  property="currentstate"   var="currentstate" value="1"></c:set>
						              		  <c:set  property="itemobj"   var="itemobj" value="${objitem}"></c:set>
						             </c:if> 
						      </c:forEach>
						      <div class="layui-input-inline"   data="${obj.value}"   style="width:60%" >
						      			<input type="hidden" value="${obj.value}"       name="itemid">
					        	 	    <input type="text" name="content"         value="<c:if test="${currentstate==1}">${itemobj.content}</c:if>"   placeholder="请输入${obj.name}" autocomplete="off" class="layui-input">
					          </div>
					            <c:if test="${currentstate==1}">
					            		 <div class="layui-form-mid layui-word-aux">${itemobj.createuserName}于${itemobj.createdate.substring(0,16)}  更新</div>
					            </c:if>  
						 </div>
					</div>	  
			</c:forEach> 
		   
		</fieldset>
		
		<div class="layui-form-item">
		    <div class="layui-input-block">
		     <c:if test="${param.owner==1}"> <button class="layui-btn layui-btn-normal" lay-submit lay-filter="">立即跟进</button>  </c:if>
		    </div>
		  </div>
	 </form> 
	</div>

<%-- 
	<input type="hidden" id="successlog" value="${successlog}">
	<input type="hidden" value="${customertype}" id="customertype">

  
				<div class="admin-tab admin-user">
					<div class="tab-condition">

						 <form class="layui-form clefix customersearcheform" action="/customer/qualificationitemlist" method="post" id="customerlistform">
  
   		<div class="layui-form-item">
			<div class="layui-input-block">
				<input type="text" name="keyWord" id="keyWord" lay-verify="title" autocomplete="off" placeholder="输入关键词后搜索" class="layui-input" value="${pager.params.KeyWord}" >
			</div>
		</div>
	 
		<div class="layui-form-item">
			<input name="skipToPage" id="skipToPage"  type="hidden" value="${pager.pageNo}">
			<input type="hidden" id="pageNo" name="pageNo" value="${pager.pageNo}">
			<input type="hidden" id="totalPage" name="totalPage" value="${pager.totalPages}">
			<input type="hidden" value="${param.cusid}"       id="cusid" name="cusid">
			<input type="hidden" value="${param.contractid}"       id="contractid" name="contractid">
			<button class="layui-btn customersearchbtn" lay-submit="" lay-filter="searchform"><i class="layui-icon layui-unselect layui-tab-close">&#xe615;<!-- &#xe642; --></i>搜索资源</button>
			<button class="layui-btn searchbtnclean" type="button" lay-submit="" lay-filter="searchform">清空搜索</button>
		</div>
	</form>
	
					    <div class="TM-tab-info"> 
							<a class="layui-btn layui-btn-primary layui-btn-small  gjjlbtn"><i class="layui-icon">&#xe654;</i>添加跟进记录</a> 
							<a class="layui-btn layui-btn-primary layui-btn-small  refreshbtn"><i class="layui-icon">&#x1002;</i>刷新</a>
						</div>
					</div>
					<div class="layui-field-box">
						<table class="site-table table-hover TM-table-news">
							<thead>
								<tr>
									<th style="width: 10%;">资质跟进人</th>
									<th style="width: 65%;">跟进内容</th>
									<th style="width: 10%;">跟进时间</th> 
									<th style="width: 15%;">操作</th> 
								</tr> 
							</thead>
							<tbody>
								<c:forEach var="obj" items="${pager.resultList}" varStatus="o1">
									<tr>
										<td>  ${obj.createuserName}</td>
										<td>${obj.content}</td>
										<td>${obj.createdate.substring(0,10)}</td> 
										<td  >
											<button type="button"
												class="layui-btn layui-btn-normal layui-btn-mini scbtn"
												data="${obj.id}">删除跟进记录</button> 
												 <button type="button"
												class="layui-btn layui-btn-normal layui-btn-mini updbtn"
												data="${obj.id}">修改跟进记录</button>
										</td>  
									</tr>
								</c:forEach>
							</tbody>
						</table>
				 
						<div class="admin-table-page">
							<div class="page">
								<div class="layui-laypage">
									<span class="layui-laypage-total"><button type="button"
											class="layui-laypage-btn">共${pager.totalSize}条记录</button></span>
								</div>
							</div>
						</div>
						<div class="admin-table-page">
							<div id="page" class="page"></div>
						</div>

					</div>
				</div>
 
 

	 
    <div class="addlgjjl"  style="display: none;">
    	<form class="layui-form" id="tjlxjlForm" action="">
	      <div class="layui-form-item address" style="margin-top:10px">
	            <label class="layui-form-label">跟进内容：</label>
	            <div class="layui-input-block" style="width:60%">
	            	 <textarea id="remark" name="remark" placeholder="请输入内容" class="layui-textarea" rows="20"   cols="20"></textarea>
	            </div>
	        </div>
	    </form>
    </div>
  
 <div class="updlgjjl"  style="display: none;">
    	<form class="layui-form" id="updtjlxjlForm" action="">
	      <div class="layui-form-item address" style="margin-top:10px">
	            <label class="layui-form-label">跟进内容：</label>
	            <div class="layui-input-block" style="width:60%">
	            	 <textarea id="updremark" name="remark" placeholder="请输入内容" class="layui-textarea"  rows="20"   cols="20"></textarea>
	            	 <input type="hidden" id="updid"   name="id" value="">
	            </div>
	        </div>
	    </form>
    </div>
   --%>


 
	<script type="text/javascript" src="<%=basePath%>js/customeritemlist.js?v=<%=callcenterstate%>16"></script>
	<script type="text/javascript">
		
	</script>
</body>
</html>